<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <script src="https://cdn.jsdelivr.net/npm/vue/dist/vue.js"></script>
</head>

<body>
  <div id="app">
   <custom-button>提交</custom-button>
   <custom-button>取消</custom-button>
   <custom-button>cancel</custom-button>
   <custom-button></custom-button>
  </div>
  <script>


    Vue.component('custom-button', {
      template: `
          <button>
          <slot>submit</slot>
          </button>
      `
    })

    var vm = new Vue({
      el: "#app",
      data: {
        username: ""
      },
      methods: {
       
      }
    })


  </script>

</body>

</html>